package com.hibase.core.i18n;

import com.hibase.core.i18n.service.MdsMessageSourceService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

import javax.annotation.PostConstruct;

/**
 * 初始化数据到redis中
 * @author chenfeng
 * @version 1.0
 * @date 2021/7/27 15:03
 * @des https://gitee.com/cheershi
 */
@Component
@Slf4j
public class InitMessageSource {


    @Autowired
    private MdsMessageSourceService mdsMessageSourceService;

    @PostConstruct
    public void init(){
        log.debug("进入国际化初始化,初始化开始");
        mdsMessageSourceService.refresh();
        log.debug("进入国际化初始化,初始化结束");
    }
}
